<?php
header("content-type:text/html;charset=utf-8");
require'mysql.php';
$name=trim($_POST['u_name']);
$pwd=trim($_POST['u_pwd']);
$zn=trim($_POST['u_zname']);
$gz=trim($_POST['u_gong']);
$sql="insert into iwebshop_users VALUES (NULL ,'$name','$pwd','$zn','$gz')";
$res=$pdo->exec($sql);
if($res)
{
    echo "<a href='list.php'>注册成功</a>";
}else{
    echo"<a href='add.html'>注册失败</a>";
}